<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title></title>
<link rel='stylesheet' type="text/css" href="__PUBLIC__/css/style.css" />
<script type="text/javascript" src="__PUBLIC__/js/jquery-1.7.2.min.js"></script>
<script type="text/javascript" src="__PUBLIC__/js/common.js"></script>
 <script language="JavaScript">
        <!--
        var URL = '__URL__';
        var APP  = '__APP__';
        var SELF='__SELF__';
        var PUBLIC='__PUBLIC__';
        //-->
        </script>
</head>
<body>
<div class="main">
    <div class="pos">{$type}
    </div>
    <div class="operate">
        <div class="left">
            <input type="button" onclick="goUrl('{:U(GROUP_NAME. '/Guestbook/add')}')" class="btn_blue" value="我要留言">
            <input type="button" onclick="doConfirmBatch('{:U(GROUP_NAME.'/Guestbook/del', array('batchFlag' => 1))}', '确实要删除选择项吗？')" class="btn_blue" value="删除">      
        </div>
    </div>
    <div class="list guestbook">    
    <form action="{:U(GROUP_NAME.'/Guestbook/delAll')}" method="post" id="form_do" name="form_do">
        <table width="100%">
            <tr>
                <th><input type="checkbox" id="check"></th>
                <th></th>
                <th>留言</th>
                <th>回复</th>
                <th>操作</th>
            </tr>
            <foreach name='vlist' item='v'>
            <tr>
                <td><input type="checkbox" name="key[]" value="{$v.id}"></td>
                <td>
                编号：{$v.id}<br/>
                姓名：<if condition="$v['userid']"><a href="{$v.userid}" target="_blank">{$v.username}</a><else/>{$v.username}</if><br/>
                 来自：{$v.ip}<br/>
                 电话：{$v.tel}<br/>
                 QQ：{$v.qq}
                </td>
                <td>{$v.content}<br/>{$v.posttime|date='Y-m-d H:i:s', ###}</td>
                <td class="reply"><if condition="$v['replytime']">{$v.reply}<br/>{$v.replytime|date='Y-m-d H:i:s', ###}</if></td>
                <td>
                    <a href="{:U(GROUP_NAME. '/Guestbook/reply',array('id' => $v['id']), '')}">回复</a>
                    <a href="javascript:;" onclick="toConfirm('{:U(GROUP_NAME. '/Guestbook/del',array('id' => $v['id']), '')}', '确实要删除吗？')">删除</a>
                </td>
            </tr>
            </foreach>
        </table>
        <div class="page" style="clear: both;">{$page}</div>
    </form>
    </div>
</div>
</body>
</html>